﻿<%@ Page Title="" Language="C#" MasterPageFile="~/mobile/MobileAdmin.master" AutoEventWireup="true" CodeFile="degree-type.aspx.cs" Inherits="mobile_degree_type" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <div data-role="content">
        <asp:HiddenField ID="UniID" runat="server" />
        <h3>Degree Type</h3>
        <asp:Chart ID="Chart5" runat="server" DataSourceID="DegreeTypeSqlDataSource" Height="300px" 
              Width="300px">
              <Series>
                  <asp:Series Name="Series1" ChartType="Pie" Legend="Legend1" XValueMember="degree_type" 
                      YValueMembers="Column1">
                  </asp:Series>
              </Series>
              <ChartAreas>
                  <asp:ChartArea Name="ChartArea1">
                  </asp:ChartArea>
              </ChartAreas>
              <Legends>
                  <asp:Legend Name="Legend1">
                  </asp:Legend>
              </Legends>
          </asp:Chart>
          <asp:SqlDataSource ID="DegreeTypeSqlDataSource" runat="server" 
              ConnectionString="<%$ ConnectionStrings:ApplicationServices %>" 
              SelectCommand="select count(*),degree_type from members where university_id=@uni group by degree_type">
              <SelectParameters>
                  <asp:ControlParameter ControlID="UniID" Name="uni" PropertyName="Value" />
              </SelectParameters>
          </asp:SqlDataSource>
    </div>
</asp:Content>

